package webapp.mvc.controllers.forms;

public class UploadFileForm {
    private String parentFolderId;
    private String fileName;
    private String mimeType;
    private String uploadType; // form, iframe
    private String jsCallback; // js的回调函数名
    private String originHost; // 如果是跨域,则可能要传入来源端的origin host,比如http://localhost:8888
    private boolean isPublic = false;

    public String getFileName() {
        return fileName;
    }

    public void setFileName(String fileName) {
        this.fileName = fileName;
    }

    public String getMimeType() {
        return mimeType;
    }

    public void setMimeType(String mimeType) {
        this.mimeType = mimeType;
    }

    public String getUploadType() {
        return uploadType;
    }

    public void setUploadType(String uploadType) {
        this.uploadType = uploadType;
    }

    public String getJsCallback() {
        return jsCallback;
    }

    public void setJsCallback(String jsCallback) {
        this.jsCallback = jsCallback;
    }

    public String getParentFolderId() {
        if("".equals(parentFolderId)) {
            return null;
        }
        return parentFolderId;
    }

    public void setParentFolderId(String parentFolderId) {
        this.parentFolderId = parentFolderId;
    }

    public String getOriginHost() {
        return originHost;
    }

    public void setOriginHost(String originHost) {
        this.originHost = originHost;
    }

    public boolean isPublic() {
        return isPublic;
    }

    public void setIsPublic(boolean isPublic) {
        this.isPublic = isPublic;
    }
}
